package com.sky.controller;


import com.sky.result.Result;
import com.sky.service.SteelMattertypeService;
import lombok.val;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;

/**
 * 仓库物料类型
 */
@Controller
@RequestMapping("/steelMatterType")
public class SteelMatterTypeController {

    @Resource
    private SteelMattertypeService steelMattertypeService;


    /**
     * 仓库物料类型 一级 包含 二级
     * @return
     */
    @RequestMapping("/list")
    @ResponseBody
    public Result list(){
        final val all = steelMattertypeService.getAll();
        return Result.success(all);
    }
}
